package com.tfswufe.xxm.controller;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.tfswufe.xxm.entity.User;
import com.tfswufe.xxm.service.UserService;
import lombok.NonNull;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@RestController
public class UserController {
    @Autowired
    private UserService userService;

    @RequestMapping("/getUser")
    public String getUser() {
        QueryWrapper queryWrapper = new QueryWrapper();
        queryWrapper.eq("id", 1);
        List<User> list = userService.list(queryWrapper);
        return String.valueOf(list);
    }

}


